﻿using System;
using System.Collections.Generic;
using System.Text;
using System.Web.UI.Design;

namespace YhmOA.Pager
{
    [Serializable]
    public class PagerDesgining : ControlDesigner
    {
        private Pager pager;

        public override string GetDesignTimeHtml()
        {
            return "<div class=\"Pager\"><a class=\"Button\">首页</a><a class=\"Button\"><<</a><a class=\"PageNumber\">1</a><a class=\"PageNumber\">2</a><a class=\"PageIndexNumber\">3</a><a class=\"PageNumber\">4</a><a class=\"PageNumber\">5</a><a class=\"Button\">>></a><a class=\"Button\">末页</a><span class=\"Span\">当前第</span><input type=\"text\" id=\"pageIndex\" name=\"pageIndex\" class=\"TextBox\" value=\"1\"/><span class=\"Span\">页，每页</span><input type=\"text\" id=\"pageSize\" name=\"pageSize\" class=\"TextBox\" value=\"10\"/><span class=\"Span\">条记录，共0页0条记录</span></div>";
        }

        public override void Initialize(System.ComponentModel.IComponent component)
        {
            base.Initialize(component);
            this.pager = component as Pager;
        }

        public override bool AllowResize
        {
            get
            {
                return false;
            }
        }
    }
}
